#pragma once
#include<iostream>
using namespace std;

class Parallelogram {
public:
//	Parallelogram() { cout << "on" << endl; }
	Parallelogram(int b, int h) :baseLength(b), height(h) { cout << "on"<<endl; }
	void calPermeter();
	void calArea();
	void showRes();

	double getnum();
private:
	double baseLength;
	double height;
	double area;
	double perimeter;

};


class Rectangle :public Parallelogram {
public:
	Rectangle(int b,int h):Parallelogram(b,h) ,height(h),baseLength(b){}
private:
	double baseLength;
	double height;
	double area;
	double perimeter;
};

class Diamond:public Parallelogram
{
public:
//	Diamond(){}
	Diamond(int b, int h) :Parallelogram(b,h),height(h), baseLength(b) {};

private:
	double height;
	double baseLength;
	double area;
	double perimeter;
};

class Square :public Diamond {
public:
	Square(int b, int h) :Diamond(b,h),height(h), baseLength(b) {}
private:
	double baseLength;
	double height;
	double area;
	double perimeter;
};
